package cz.proks.easyhelpdesk.gae.api.impl.dbo;

import cz.proks.easyhelpdesk.gae.api.impl.dbo.base.ConvertibleDbo;

public class HelpdeskRole implements ConvertibleDbo<cz.proks.easyhelpdesk.api.model.HelpdeskRole>{
    private Long id;
    private cz.proks.easyhelpdesk.api.model.HelpdeskRole role;
    
    public Long getId() {
        return id;
    }
    
    public void setId(Long id) {
        this.id = id;
    }
    
    public cz.proks.easyhelpdesk.api.model.HelpdeskRole getRole() {
        return role;
    }
    
    public void setRole(cz.proks.easyhelpdesk.api.model.HelpdeskRole role) {
        this.role = role;
    }
    
    @Override
    public void toDbo(cz.proks.easyhelpdesk.api.model.HelpdeskRole domain) {
        setId((long) domain.ordinal());
        setRole(domain);
    }
    @Override
    public cz.proks.easyhelpdesk.api.model.HelpdeskRole asDomain() {
        return role;
    }            
}
